Skip to content

Migrate to Gradle version catalogs #2337

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jul 9, 2025
Merged

Conversation

DavideD
Copy link
Member

@DavideD DavideD commented Jul 8, 2025

Follows #2331
Fix #1989

@exoego, I reverted the checks you have removed and made a few changes. Now we have the versions in the catalog but we also have the same behaviour as before.

I've also fixed a few mistakes I found along the way. I will apply these changes to other branches and make sure that everything still works.

@DavideD DavideD force-pushed the 2331-catalogs branch 2 times, most recently from c02fbda to 27b3f24 Compare July 8, 2025 14:35
Copy link
Member

@sebersole sebersole left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I cannot really speak to the VersionsPlugin / VersionsTomlParser as I am not familar with the purpose, but the rest looks great

@DavideD
Copy link
Member Author

DavideD commented Jul 8, 2025

I think you have introduced the VersionsPlugin class to check that there are no errors in the versions name. The logic was initially in the gradle build and you moved it in a plugin (this is on top of my head).

But the VersionsPlugin expects to have a property with the Hibernate ORM version somewhere.
Before we had it in the gradle.properties or command line, but now the version is declared in the catalog and there's no property in the default build. This causes the plugin to fail.

I've created the VersionsTomlParser to read the versions from the catalog as a fallback.

I have the feeling that we can simplify a bit some part of this process, but I guess we can do it as a separate issue.

@DavideD
Copy link
Member Author

DavideD commented Jul 8, 2025

I cannot really speak to the VersionsPlugin / VersionsTomlParser as I am not familar with the purpose, but the rest looks great

Thanks for checking!

Copy link
Contributor

@exoego exoego left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am fine with this change

@DavideD DavideD added build Something related to the build and removed build Something related to the build labels Jul 9, 2025
@DavideD DavideD merged commit 0f53e6d into hibernate:main Jul 9, 2025
19 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Consider using Gradle version catalogs
3 participants